/*
    SUSAN® - Sole of Unix Save ANything

   Copyright (C) 2020-2020 Hechzh Property

   
*/

#ifndef BAREOS_SRC_DIRD_DBCOPY_DATABASE_IMPORT_H_
#define BAREOS_SRC_DIRD_DBCOPY_DATABASE_IMPORT_H_

class BareosDb;
class DatabaseConnection;
class DatabaseExport;
class DatabaseTableDescriptions;

class DatabaseImport {
 public:
  DatabaseImport(const DatabaseConnection& db_connection);
  virtual ~DatabaseImport();

  virtual void ExportTo(DatabaseExport& exporter) = 0;

  static std::unique_ptr<DatabaseImport> Create(
      const DatabaseConnection& db_connection,
      std::size_t maximum_amount_of_rows);

 protected:
  BareosDb* db_{};

  std::unique_ptr<DatabaseTableDescriptions> table_descriptions_;
};


#endif  // BAREOS_SRC_DIRD_DBCOPY_DATABASE_IMPORT_H_
